package edu.gyc.service;

import edu.gyc.dao.GirlDao;
import edu.gyc.model.Girl;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;
import java.util.Collection;

@Service
public class GirlServiceImpl implements GirlService {

    private GirlDao girlDao;

    public GirlDao getGirlDao() {
        return girlDao;
    }
    @Resource(name = "girlDao")
    public void setGirlDao(GirlDao girlDao) {
        this.girlDao = girlDao;
    }

    @Override
    public Collection<Girl> queryGirls() {
        return girlDao.getGirls();
    }
}
